<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>博客编辑</title>
    <script src="/resources/scripts/jquery-3.2.1.min.js"></script>
</head>
<body>
    <div class="container">
        <img class="background" src="/resources/images/bg.svg" alt="">
        <div class="header">
            <div class="to-back">
                <img src="/resources/images/back.svg" alt="">
            </div>
            <div class="title">
                <span>博客编辑</span>
            </div>
            <div class="search">
                <img src="/resources/images/search.svg" alt="">
            </div>
        </div>
        <hr class="split-line">
        <div class="edit-container">
            <div class="button-box">
                <button class="submit-button">发布</button>
            </div>
            <div class="edit-box" >
                <p style="color: white; margin-left: 12px">博文标题：</p>
                <input type="text" class="title-input" placeholder="请输入博文标题">
                <p style="color: white; margin-left: 12px">博文内容：</p>
                <textarea name="" id="blog-content" cols="30" rows="10"></textarea>
            </div>
        </div>

        <form id="picForm" action="your_upload_url.php" method="POST" enctype="multipart/form-data">
            <input type="file" name="files[]" id="fileInput" multiple accept="image/gif, image/jpeg, image/png, image/jpg">
            <!-- <button type="submit">上传</button> -->
        </form>

        <div id="previewContainer">
            <div id="addPicImg">
                <img src="/resources/images/plus-icon.svg" alt="" >
            </div>
        </div>

        <div id="option-container">
            <span style="color: white">投稿分区：</span>
            <form id="optionForm">  
                <div>
                    <input name="partition" value="life"id="life" type="radio"> 
                    <label value="radio" class="labelclass">生活动态</label>
                </div>
                <div>
                    <input name="partition" value="tease"id="tease" type="radio">  
                    <label value="radio1" class="labelclass">吐槽分享</label>  
                </div>
                <div>
                    <input name="partition" value="learning"id="learning" type="radio">  
                    <label value="radio2" class="labelclass">学习交流</label>  
                </div>
                <div>
                    <input name="partition" value="study"id="study" type="radio">  
                    <label value="radio3" class="labelclass">考研专题</label>  
                </div>
                <div>
                    <input name="partition" value="consult" id="consult" type="radio">  
                    <label value="radio4" class="labelclass">吐槽分享</label>  
                </div>
                <div>
                    <input name="partition" value="other" id="other" type="radio">  
                    <label value="radio5" class="labelclass">吐槽分享</label>  
                </div>
            </form>  
        </div>
    </div>
</body>
<style>
    body{
        width: 375px;
        height: 812px;
    }
    .container{
        width: 100%;
        height: 100%;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .background{
        position: absolute;
        z-index: -1;
        width: 375px;
        height: 814px;
    }

    .header{
        width: 90%;
        height: 65px;
        display: flex;
        align-items: center;
        justify-content: space-between;
    }

    .title{
        font-size: 22px;
        font-weight: lighter;;
        color: white;
        display: flex;
        flex-direction: column;
        align-self: flex-end;
    }
    .split-line{
        width: 100%;
        height: 1px;
        background-color: white;
        opacity: 0.4;
        border: none;
    }

    .edit-container{
        width: 100%;
        height: 100%;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .button-box{
        width: 100%;
        display: flex;
        flex-direction: row-reverse;
        justify-self: flex-end;
    }

    .submit-button{
        width: 70px;
        height: 33px;
        border-radius: 20px;
        border: 0px;
        align-self: flex-end;
        background-image: url("/resources/images/u472.svg");
        color: white;
        font-size: 16px;
    }

    .edit-box{
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: flex-start;
    }

    .title-input{
        width: 95%;
        height: 40px;
        border: 0px;
        border-radius: 5px;
        opacity: 0.4;
        font-size: 20px;
    }

    #blog-content{
        width: 95%;
        height: 200px;
        border: 0px;
        border-radius: 5px;
        opacity: 0.4;
        font-size: 20px;
    }

    #previewContainer{
        width: 100%;
        height: 100%;
        display: flex;
        flex-direction: row;
        flex-wrap: wrap;
    }

    #picForm{
        display: none;
    }

    #addPicImg{
        width: 100px;
        height: 100px;
        background-color: #b5e8fa;
        border-radius: 5px;
        display: flex;
        justify-content: center;
        align-items: center;
        margin: 5px;
    }
    #addPicImg img{
        width: 50%;
        height: 50%;
        opacity: 1;
    }

    #option-container{
        width: 100%;
        height: 100%;
        display: flex;
        flex-direction: row;
        align-items: flex-start;
    }

    #optionForm{
        width: 70%;
        display: flex;
        flex-direction: row;
        flex-wrap: wrap;
    }

    .labelclass{
        color: white;
    }
</style>

<script type="text/javascript" src = "/js/blogEdit.js"></script>
</html>